PyTorch Transformations#215
Conversation
|
The CropPad was a bit of a red herring. That transform is very special. It is not used as an augmentation, rather it is the function with which we go from input data of arbitrary shape and dimensions to the required dimensions.
Therefore for Blur you can assume that data will be either 3D (H,W,D) or 2D and should stay in those dimensions. I will prepare a draft for how to package it and add that to your PR if that's fine? :) |
|
I'm a bit afraid of the "deform_coordinate_matrix" in torch_spatial. Can be a rather expensive operation and that one is still np/cpu Edit: yes so I just tried this. The spatial func runs in 14 secs when using "deform_coordinate_matrix" and 1 sec when not using it, so that part definitely hurts |
|
Modified the spatial impl. Trying with 3 separable 1D gauss convs as approximating kernels. Kernel sizes are fixed (suggest: hyper search good general size). Visually I don't see a difference, I haven't done thorough performance measures. ALSO: Looked at Kornia's impl. Couldn't find a 3D gaussian fn @Sllambias ?? Do u have a good bench to test if there's "mere knald på nu"? xD |
… as expected by torch grid_sample
Sllambias
left a comment
There was a problem hiding this comment.
Absolutely lovely, only thing is: will you upload the script you used to generate the plot aswell? Somewhere in the /documentation directory where you see fit
Apart from that lgtm!
Uh oh!
There was an error while loading. Please reload this page.